﻿using UnityEngine;
using System.Collections;

[RequireComponent(typeof(UIWidget))]
public class MeStretch : UIViewAuto
{
		private UIWidget widget;

		// Use this for initialization
		void Awake ()
		{
				widget = gameObject.GetComponent<UIWidget> ();
				contentSize = new Vector2 (widget.width, widget.height);
		}
	
		public override bool setAutoHeight (float autoHeight)
		{
				widget.height = (int)autoHeight;
				return base.setAutoHeight (autoHeight);
		}
}
